package com.xinyi.reactivemvvmkt.ui.activity

import androidx.activity.viewModels
import com.xinyi.reactivemvvmkt.R
import com.xinyi.reactivemvvmkt.base.activity.BaseViewBindingActivity
import com.xinyi.reactivemvvmkt.databinding.ActivityMainBinding
import com.xinyi.reactivemvvmkt.viewmodel.MainViewModel
import dagger.hilt.android.AndroidEntryPoint
import com.xinyi.reactivemvvmkt.ui.fragment.HomeFragment

/**
 * @author 杨耿雷
 * @date 2024/9/24 21:45
 * @description 应用主页
 */
@AndroidEntryPoint
class MainActivity : BaseViewBindingActivity<ActivityMainBinding>() {

    private val mMainViewModel: MainViewModel by viewModels()

    override fun initLayoutId(): Int {
        return R.layout.activity_main
    }

    override fun initParams() {
        super.initParams()

        val homeFragment = HomeFragment.newInstance()
        supportFragmentManager.beginTransaction().replace(R.id.fl_container, homeFragment).commit()
    }
}
